package com.jasiri.project.pro

import android.content.Context
import android.view.Gravity
import android.view.WindowManager
import com.jasiri.project.R
import com.jasiri.project.app.App

abstract class ProDialog(context: Context?): com.jasiri.project.base.BaseDialog(context) {

    override fun initWindow() {
        val params = window?.attributes
        params?.width = App.getPhoneWidth() - com.jasiri.project.utils.DensityUtils.dp2px(60f)
        params?.height = WindowManager.LayoutParams.WRAP_CONTENT
        window?.attributes = params
        window?.setWindowAnimations(R.style.dialog_scale_anim) //修改动画样式
        window?.setGravity(Gravity.CENTER)
    }
}